<!DOCTYPE html>
<html>
  <head>
    <meta charset="UTF-8" />
    <meta http-equiv="x-ua-compatible" content="IE=edge" />
    <meta
      name="viewport"
      content="width=device-width, height=device-height, initial-scale=1, maximum-scale=1, minimum-scale=1, user-scalable=no"
    />
    <title>Vod</title>
    <link rel="stylesheet" href="//g.alicdn.com/de/prismplayer/2.6.0/skins/default/aliplayer-min.css"/>
    <script type="text/javascript" src="//g.alicdn.com/de/prismplayer/2.6.0/aliplayer-min.js"></script>
    <script src="https://cdn.bootcss.com/axios/0.19.2/axios.js"></script>
  </head>
  <body>
    <div class="prism-player" id="J_prismPlayer"></div>
    <script>
      // 0e463b92c21d40e08b33bd368ec58e37 未转码
      // 1b2242b2902f4ad98293009a0a5495f5 已转码
      // 4d52b2e88f894d2f8fc185ef3ddfdbbe mp4
      axios.get('/vod/videoPlayAuth?VideoId=4d52b2e88f894d2f8fc185ef3ddfdbbe').then(resp => {
        let data = resp.data
        // console.log(resp)
        var player = new Aliplayer({
          id: 'J_prismPlayer',
          autoplay: false,
          preload: false,
          // format: 'mp4', //mp4、m3u8
          width: '100%',
          vid: data.VideoMeta.VideoId,
          playauth: data.PlayAuth,
          // cover: data.VideoMeta.CoverURL
          cover: 'https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1585046785286&di=138776b8cd4beb5cd0b3e8c2cbc7f1a3&imgtype=0&src=http%3A%2F%2Fb-ssl.duitang.com%2Fuploads%2Fitem%2F201603%2F08%2F20160308211105_kXTsR.thumb.700_0.jpeg'
        })
      })
      
    </script>
  </body>
</html>
